package com.sxl.domain;

import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.ContentRowHeight;
import com.alibaba.excel.annotation.write.style.HeadRowHeight;
import lombok.Data;

import java.io.Serializable;

/**
 * @ProjectName: CRMProject
 * @Package: com.sxl.domain
 * @Author songxueliang
 * @Date 2022/5/1 12:17
 */
@Data
@HeadRowHeight(value = 35)
@ContentRowHeight(value = 25)
public class Students_export implements Serializable {
    @ExcelProperty({"学生信息", "编号"})
    private Integer id;

    @ExcelProperty({"学生信息", "姓名"})
    private String name;

    @ExcelProperty({"学生信息", "年龄"})
    private Integer age;

    @ExcelProperty({"学生信息", "性别"})
    private String sex;

    @ExcelProperty({"学生信息", "手机号"})
    private String phone;

    @ExcelProperty({"学生信息", "QQ"})
    private String QQ;

    @ExcelProperty({"学生信息", "微信"})
    private String weixin;

    @ExcelIgnore
    private Integer stuStatus;

    @ExcelProperty({"学生信息","状态"})
    private String statusName;

    public String getStatusName() {
        if (stuStatus==1){
            return statusName = "已录入未分配";
        }else if (stuStatus==2){
            return statusName = "已分配咨询师";
        }else if (stuStatus==3){
            return statusName = "正在跟踪";
        }else if (stuStatus==4){
            return statusName = "跟踪结束（已缴费）";
        }else {
            return statusName = "跟踪结束（失败）";
        }
    }

    @ExcelProperty({"学生信息", "创建时间"})
    private String createTime;

    @ExcelProperty({"学生信息", "第一次跟踪时间"})
    private String firstVisitTime;

    @ExcelIgnore
    private int isPay;

    @ExcelProperty({"学生信息", "是否付款"})
    private String isPayName;

    public String getIsPayName() {
        if (isPay==1){
            return isPayName="未付款";
        }else {
            return isPayName="已付款";
        }
    }

    @ExcelProperty({"学生信息", "付款时间"})
    private String payTime;

    @ExcelProperty({"学生信息", "付款金额"})
    private String money;
}
